package cn.wolfcode.luowowo.gold.domain;

import cn.wolfcode.luowowo.common.domain.BaseDomain;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.math.BigDecimal;

@Data
@AllArgsConstructor
@NoArgsConstructor
public class GoldProduct extends BaseDomain{
    public static final int STATE_NORMAL = 0;  //正常
    public static final int STATE_PUBLISH = 1; //每日推荐
    public static final int STATE_down = -1; //下架

    private String productName;

    private String subTitle;

    private BigDecimal actualPrice;

    private BigDecimal originalPrice;

    private Integer salesNum;

    private String productColor;

    private String coverUrl;

    private GoldProductType productType;

    private GoldProductType productTypeParent;

    private Integer convertGoldNum;

    private String state;

    private String productSize;

    private String brand;
    private Integer sequence;

    public String getOneCoverUrl() {
        String[] imgArr = coverUrl.split(";");
        return imgArr[0];
    }

    //返回一个图片数组
    public String[] getImgArr(){
        return coverUrl.split(";");
    }



}